import axios from 'axios';
import apiClient from '@/services/axiosConfig';
import router from '@/router';

export const hospitalListApi = async () => {

    try {
        const response = await axios.get('http://localhost:9000/hospital/list')
        return response.data;
    } catch (error) {
        console.error(error)
    }
}

export const getHospitalApi = async (data) => {

    try {
        const response = await axios.get(`http://localhost:9000/hospital/getHospitalInfo?hpId=${data}`)
        return response.data;
    } catch (error) {
        console.error(error)
    }
}